local suilin = fk.CreateSkill{
  name = "swis__suilin",
  tags = {Skill.Compulsory},
}

Fk:loadTranslationTable{
  ["swis__suilin"] = "碎鳞",
  [":swis__suilin"] = "锁定技，当你对其他角色造成伤害时，若其没有可以使用的手牌，此伤害+1。",

  ["$swis__suilin1"] = "敌势已缓，休要走了老贼！",
  ["$swis__suilin2"] = "精兵如炬，困龙难飞！",
}

local U = require "packages/utility/utility"

suilin:addEffect(fk.DamageCaused, {
  can_trigger = function (self, event, target, player, data)
    if player:hasSkill(suilin.name) and player == target and player ~= data.to then
      return not table.find(data.to:getCardIds("h"), function(id)
        return #Fk:getCardById(id):getDefaultTarget(data.to, { bypass_times = true }) > 0
      end)
    end
  end,
  on_cost = Util.TrueFunc,
  on_use = function (self, event, target, player, data)
    local room = player.room
    room:doIndicate(player, {data.to})
    data.damage = data.damage + 1
  end
})

return suilin